package com.sikaryofficial.backend.domain.mapping;

import com.sikaryofficial.backend.domain.dto.req.prize.PrizeReq;
import com.sikaryofficial.backend.domain.dto.resp.prize.PrizeDTO;
import com.sikaryofficial.backend.domain.entity.Prize;
import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;

/**
 * @author : qinjinyuan
 * @desc : 活动映射接口
 * @date : 2023/11/03 9:19
 */
@Mapper
public interface PrizeMapping {
    PrizeMapping INSTANCE = Mappers.getMapper(PrizeMapping.class);

    /**
     * req映射实体
     *
     * @param req
     * @return
     */
    Prize coverReqToEntity(PrizeReq req);

    /**
     * 实体映射为DTO
     *
     * @param req
     * @return
     */
    PrizeDTO coverToDTO(Prize req);
}
